package com.craney.aboutXML
{
	import flash.accessibility.Accessibility;
	
	public class FirstXML
	{
		public function FirstXML()
		{
			XML.ignoreComments = false;
			XML.ignoreProcessingInstructions = false;
			XML.ignoreWhitespace = true;
			var myXML:XML = 
				<order>
					<!-- Here you are -->
					<item id="1">
						<menuName>burger dddd</menuName>
						<price>3.95</price>
					</item>
					<item id="2">
						<menuName>fries</menuName>
						<price>1.45</price>
					</item>
					<!-- shi -->
				</order>;
				
				
			myXML.item.(@id=='2').@id='23';
			trace(myXML.item[0]);
			
			var newNode:XML = 
				<yao>
					supers
				</yao>;
			
//			myXML.item.(menuName=="burger").appendChild(newNode);
			myXML.item.(menuName=="fries").appendChild(newNode);
			trace("~~~~~~~~~~~~~~~~~~");
			trace(myXML);
			trace("------------------");
			trace(myXML.comments().toXMLString());
			
			
			
			
		}

	}
}